package recommenRatings.domain;

import java.util.Date;

public class Message {


	private String receptor, sender;
	private String subject;
	private String text;
	private Date date;
	private boolean read;
	private String ID;

	public String getID() {
		return ID;
	}

	public void setID(String iD) {
		ID = iD;
	}

	public Message(String receptor, String sender, String subject,
			String text, Date date, boolean read) {
		java.util.Date fecha = new Date();
		
		
		this.receptor = receptor;
		this.sender = sender;
		this.subject = subject;
		this.text = text;
		this.date = fecha;
		this.read = read;
	}

	public Message() {
	
		this.receptor = null;
		this.sender = null;
		this.subject = null;
		this.text = null;
		this.date = null;
		this.read = false;

	}


	public void setText(String text) {
		this.text = text;
	}

	public String getText() {
		return text;
	}

	public void setDate(Date date) {
		this.date = date;
	}

	public Date getDate() {
		return date;
	}

	public void setRead(boolean read) {
		this.read = read;
	}

	public boolean isRead() {
		return read;
	}

	public String getReceptor() {
		return receptor;
	}

	public void setReceptor(String receptor) {
		this.receptor = receptor;
	}

	public String getSender() {
		return sender;
	}

	public void setSender(String sender) {
		this.sender = sender;
	}

	public String getSubject() {
		return subject;
	}

	public void setSubject(String subject) {
		this.subject = subject;
	}

	@Override
	public String toString() {
		return "Message [date=" + date + ", read=" + read + ", receptor="
				+ receptor + ", sender=" + sender + ", subject=" + subject
				+ ", text=" + text + "]";
	}

}
